<?php if(user_access('edit party')):?>
	<?php print l(theme('image', drupal_get_path('module', 'sndvivill').'/images/edit.png', t('Edit')), 'vivill/party/'.$data['party_id'].'/edit',  array('html' => 'true'));?>
<?php endif;?>
<p>
	<?php print $data['info'];?>
</p>

<table id="vivilldocuments" class="tablesorter">
    <thead>
		<tr>
			<th class="header headerSortUp"><?php print t('Year');?></th>
			<th class="header"><?php print t('Title');?></th>
		</tr>
	</thead>
	<tbody>
		<?php foreach($data['docs'] as $doc){ ?>
		<tr>
			<td><?php print $doc['year'];?></td>
			<td><img src="/<?php print drupal_get_path('module', 'sndvivill');?>/include/<?php print $doc['type'];?>.png" alt="<?php print $doc['type'];?>"><?php print l($doc['title'], $doc['link']);?></td>
		</tr>
		<?php }?>
	</tbody>
</table>